# Maintainer: Pedro Filipe <xpecex@outlook.com>
pkgname=gobuster
pkgver=3.1.0
pkgrel=5
pkgdesc="Directory/File, DNS and VHost busting tool written in Go"
url="https://github.com/OJ/gobuster"
arch="all !s390x"
license="Apache-2.0"
makedepends="go"
source="$pkgname-$pkgver.tar.gz::https://github.com/OJ/gobuster/archive/v$pkgver.tar.gz"

build() {
	go build -ldflags "-s -w" \
		-gcflags="all=-trimpath=$GOPATH/src" \
		-asmflags="all=-trimpath=$GOPATH/src" \
		-o build/gobuster
}

check() {
	make test
}

package() {
	install -Dm755 "./build/gobuster" "$pkgdir/usr/bin/gobuster"
}

sha512sums="956789e83aca3a06e04080ecf8bb723328b717019abf6b749e600c6e632c2c6a39b8ac9293521ed82c309cdcf3402a0a88107b62590d74e8947958f625c3de20  gobuster-3.1.0.tar.gz"
